<template>
  <div class="company-style">
    <!-- 导航栏 start -->
    <van-nav-bar title="开通会员" left-arrow fixed @click-left="$router.back()"/>
    <!-- 导航栏 end -->

    <!-- 内容 start -->
    <div class="content-top my-membership">
      <!-- 客服信息 -->
      <div class="name" v-if="responseData.memberType=='试用会员'">
        <b>客服：{{responseData.kfRandName}}</b>
        <span>您还不是舟山人才网的会员<br />可联系客服开通企业会员</span>
      </div>
			<div class="name" v-else>
        <b>专属客服：{{responseData.kfRealName}}</b>
				<span>亲爱的HR，如有疑问请联系您的专属客服</span>
      </div>

      <!-- 客服联系 -->
      <div class="contact">
        <small>联系我</small>
        <!-- <van-button block round type="primary" icon="wechat" text="发微信" color="#08f" @click="onWx"></van-button> -->
        <van-button block round type="primary" icon="phone" text="打电话" color="#09f" @click="onTel"></van-button>
      </div>
    </div>
    <!-- 内容 end -->
  </div>
</template>
  
  <script>
import { NavBar, Button } from "vant";
import { returnToPhoneWithData } from '@/util/phone';
export default {
  name: "MemberShip",
  components: {
    [NavBar.name]: NavBar,
    [Button.name]: Button,
  },
  // 定义属性
  data() {
    return {
			responseData:{}
		};
  },
	mounted(){
		this.loadData()
	},
  // 方法集合
  methods: {
		loadData(){
			this.$api.get('/CompanyAccount/GetMemberInfo').then(res=>{
				if(res.success){
					this.responseData = res.response;
				}
				else{Toast(res.msg);}
			})
		},
		onWx(){
			console.log(this.responseData.kfwx)
		},
		onTel(){
			returnToPhoneWithData({action:'call',tel:this.responseData.kfTel})
		}
	},
};
</script>
<style lang="less">
@import "vant/lib/index.less";
@import "@/assets/css/company.less";
@import "@/assets/css/company.css";
</style>